/**
 * Author(s): xuming.Wong <xuming.Wong@gmail.com>
 */

#ifndef __PQ_TransformComponent_H__
#define __PQ_TransformComponent_H__

#include "Component.h"

namespace PQEngine
{
	/*This component is represent of game object world transform.
	Every game object should have this component.
	*/
	class TransformComponent
		: public Component
	{
	private:
		Ogre::Vector3 _position;
		Ogre::Vector3 _scale;
		Ogre::Quaternion _orientation;
	public:
		TransformComponent();
		~TransformComponent();

		inline void setPosition(Ogre::Vector3 position){ _position=position;}
		inline void setPosition(float x,float y,float z){_position.x=x;_position.y=y;_position.z=z;}

		inline Ogre::Vector3 getPosition(){return _position;}
		
		inline void setOrientation(float w,float x,float y,float z){_orientation.w=w; _orientation.x=x; _orientation.y=y;_orientation.z=z;}
		inline void setOrientation(Ogre::Quaternion orient){_orientation=orient;}
		inline Ogre::Quaternion getOrientation(){return _orientation;}

		inline void setScale(float x,float y,float z){_scale.x=x;_scale.y=y;_scale.z=z;}
		inline void setScale(Ogre::Vector3 scale){_scale=scale;}
		inline Ogre::Vector3 getScale(){return _scale;}
	};
}
#endif
